<template>
  <div class="app-page">
    <tab-bar
      :tab-list="tabList"
      :active="active"
      :type="type"
      @change="changeTab"
    />
    <template v-if="active==='riskTrack'">
      <risk-track />
    </template>
    <template v-if="active==='inspection'">
      <inspection />
    </template>
  </div>
</template>
<script>
  import tabBar from '@/components/Tabs'
  import inspection from './components/inspection.vue'
  import riskTrack from '../riskTrack'
  export default {
    name: 'Equipment',
    components: {
      tabBar,
      riskTrack,
      inspection
    },
    data() {
      return {
        type: 'card',
        active: 'riskTrack',
        tabList: [
          { label: '隐患追踪', value: 'riskTrack' },
          { label: '复检单查询', value: 'inspection' }
        ],
        corpList: []
      }
    },
    created() {
    },
    methods: {
      changeTab(val) {
        this.active = val
      }
    }

  }
</script>

